﻿using System;
using System.Collections.Generic;
using System.Web;
using System.Configuration;
using System.Collections;


namespace HISRestServices {

    public abstract class ContextWrapper :  IDisposable {

        #region Fields
        private HISModels.HISContext _AppContect = null;
        #endregion

        #region Properties
        public HISModels.HISContext AppContext {
            get {
                return _AppContect;
            }
        }

        #endregion

        #region Constructors
        public ContextWrapper() {
            _AppContect = new HISModels.HISContext("DBConn");
            //_AppContect.Configuration.LazyLoadingEnabled = false;
            _AppContect.Configuration.ProxyCreationEnabled = false;
        }
        #endregion

        public void Dispose() {
            _AppContect.Dispose();
        }



    }
}